//
//  User.m
//  iRMAP
//
//  Created by Ryan Enguero on 4/2/14.
//  Copyright (c) 2014 engueroryan. All rights reserved.
//

#import "User.h"

@implementation User

- (NSString*)userID{

    return _userIDStr;
}

- (NSString*)sessionTimeOut{

    return _sessionTimeOutStr;
}

- (NSString*)sessionID{

    return _sessionIDStr;
}

- (NSString*)firstName{

    return _firstNameStr;
}

- (NSString*)lastName{

    return _lastNameStr;
}

- (NSString*)role{

    return _roleStr;
}

- (NSString*)email{

    return _emailStr;
}

- (NSString*)phone{

    return _phoneStr;
}

+ (instancetype)userWithUserID:(NSString*)idUser andSessionTimeOut:(NSString*)sessionTimeOut andSessionID:(NSString*)idSession andFirstName:(NSString*)fName andLastName:(NSString*)lName andRole:(NSString*)role andEmail:(NSString*)email andPhone:(NSString*)phone{

    User *user = [[self alloc] init];
    
    user.userIDStr = idUser;
    user.sessionTimeOutStr = sessionTimeOut;
    user.sessionIDStr = idSession;
    user.firstNameStr = fName;
    user.lastNameStr = lName;
    user.roleStr = role;
    user.emailStr = email;
    user.phoneStr = phone;
    
    return user;
}

@end
